Optimal. Leaf size=11 \[ \tanh ^{-1}\left (\sqrt {1+\cos ^2(x)}\right ) \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.02, antiderivative size = 11, normalized size of antiderivative = 1.00, number of steps
used = 3, number of rules used = 3, integrand size = 13, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.231, Rules used = {3273, 65, 213}
\begin {gather*} \tanh ^{-1}\left (\sqrt {\cos ^2(x)+1}\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 65
Rule 213
Rule 3273
Rubi steps
\begin {align*} \int \frac {\tan (x)}{\sqrt {1+\cos ^2(x)}} \, dx &=-\left (\frac {1}{2} \text {Subst}\left (\int \frac {1}{x \sqrt {1+x}} \, dx,x,\cos ^2(x)\right )\right )\\ &=-\text {Subst}\left (\int \frac {1}{-1+x^2} \, dx,x,\sqrt {1+\cos ^2(x)}\right )\\ &=\tanh ^{-1}\left (\sqrt {1+\cos ^2(x)}\right )\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.01, size = 11, normalized size = 1.00 \begin {gather*} \tanh ^{-1}\left (\sqrt {1+\cos ^2(x)}\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.07, size = 10, normalized size = 0.91
method | result | size |
derivativedivides | \(\arctanh \left (\frac {1}{\sqrt {1+\cos ^{2}\left (x \right )}}\right )\) | \(10\) |
default | \(\arctanh \left (\frac {1}{\sqrt {1+\cos ^{2}\left (x \right )}}\right )\) | \(10\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [B] Leaf count of result is larger than twice the leaf count of optimal. 60 vs.
\(2 (9) = 18\).
time = 0.48, size = 60, normalized size = 5.45 \begin {gather*} \frac {1}{2} \, \log \left (\frac {\sqrt {-\sin \left (x\right )^{2} + 2}}{\sin \left (x\right ) + 1} + \frac {1}{\sin \left (x\right ) + 1} - 1\right ) + \frac {1}{2} \, \log \left (-\frac {\sqrt {-\sin \left (x\right )^{2} + 2}}{\sin \left (x\right ) - 1} - \frac {1}{\sin \left (x\right ) - 1} + 1\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.41, size = 16, normalized size = 1.45 \begin {gather*} \log \left (\frac {\sqrt {\cos \left (x\right )^{2} + 1} + 1}{\cos \left (x\right )}\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\tan {\left (x \right )}}{\sqrt {\cos ^{2}{\left (x \right )} + 1}}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 27 vs.
\(2 (9) = 18\).
time = 0.44, size = 27, normalized size = 2.45 \begin {gather*} \frac {1}{2} \, \log \left (\sqrt {\cos \left (x\right )^{2} + 1} + 1\right ) - \frac {1}{2} \, \log \left (\sqrt {\cos \left (x\right )^{2} + 1} - 1\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.09 \begin {gather*} \int \frac {\mathrm {tan}\left (x\right )}{\sqrt {{\cos \left (x\right )}^2+1}} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________